/*
 * File: exercise7.cpp
 * -------------------
 * remove all characters of one string which occurs in another string
 * compile command :
 * g++ -Wall -g exercise7.cpp -o exercise7 -lStanfordCPPLib -I ../include/
 */

#include <iostream>
#include <string>
using namespace std;

string removeCharacters(string str, string remove);

int main(void)
{
	cout << removeCharacters("counterrevolutionaries", "aeiou") <<endl;
	return 0;
}

string removeCharacters(string str, string remove)
{
	int len = str.length();
	string result= "";
	for(int i = 0; i < len; i++)
	{
		if(remove.find(str[i]) == string::npos)
			result += str[i];
	}
	return result;
}
